package com.hellomeng.bean;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class TestDataSourceBean {
    public static void main(String[] args) {
        ApplicationContext applicationContext = new ClassPathXmlApplicationContext("applicationContext.xml");
        DataSourceBean datasource = (DataSourceBean)applicationContext.getBean("datasource");
        System.out.println(datasource.getUrl());
    }
}
